In coding an audio signal or a speech signal, in addition to an actual frequency component of a spectrum, side information such as energy or an envelope may be added into a bitstream. In this case, the number of bits allocated for coding a frequency component of a spectrum increases by reducing the number of bits allocated for coding side information in a state where loss is minimized.
That is, in a case of coding or decoding an audio signal or a speech signal, it is required to reconstruct the audio signal or the speech signal having the best quality of a sound in a corresponding bit range by efficiently using limited bits especially at a low bit rate.